<
key, pattern>
pairs
can be compiled in a list. A global function can then be invoked to
process each pair for the entire document or parts of it.
This list can be created off-line by the user, or automatically
in an incremental fashion as the
user confirms new index insertions in an interactive session. The pattern
matching mechanism must be able to recognize and skip instances already
indexed so that unnecessary repetitions are avoided.
In our system, this key-pattern list is a per document list.
If a document includes multiple files, the global function processes
each of them according to the preorder traversal of the file inclusion tree.